package com.example.demo.dto;

import com.alibaba.excel.annotation.ExcelProperty;
import lombok.EqualsAndHashCode;
import lombok.Getter;
import lombok.Setter;

import java.io.Serializable;
import java.util.StringJoiner;

@Getter
@Setter
@EqualsAndHashCode
public class UserDto extends ExcelImportCommonDto implements Serializable {

    @ExcelProperty("姓名")
    private String name;
    @ExcelProperty("年龄")
    private Integer age;
    @ExcelProperty("邮箱")
    private String email;


    @Override
    public String toString() {
        final StringBuilder sb = new StringBuilder();
        sb.append("{")
                .append("\"super\":").append(super.toString()).append(", ")
                .append("\"name\":").append(name)
                .append(", \"age\":").append(age)
                .append(", \"email\":").append(email)
                .append('}');
        return sb.toString();
    }
}